package com.yanmaohu.yulia.bean;

import java.util.List;

/**
 * @author Bright Lee
 */
public final class MethodCharacteristics {

    private int beginIndex;
    private int endIndex;
    private List<MethodCharacteristic> methodCharacteristicList;

    public MethodCharacteristics(List<MethodCharacteristic> methodCharacteristicList) {
        this.beginIndex = methodCharacteristicList.get(0).getBeginIndex();
        this.endIndex = methodCharacteristicList.get(methodCharacteristicList.size() - 1).getEndIndex();
        this.methodCharacteristicList = methodCharacteristicList;
    }

    public int getBeginIndex() {
        return beginIndex;
    }

    public int getEndIndex() {
        return endIndex;
    }

    public int size() {
        return methodCharacteristicList.size();
    }

    public MethodCharacteristic get(int index) {
        return methodCharacteristicList.get(index);
    }

}
